package org.example;

import org.springframework.amqp.core.AmqpTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.xml.ws.RequestWrapper;

@RestController
public class SenderController {

    @Autowired
    @AmqpTemplate amqpTemplate;

    @RequestMapping("/send")
    public String Send(String msg){
        amqpTemplate.convertAndSend("queue_msg",msg);
        return "YEAP";
    }
}
